/* 登录页面样式 - 基于提供的模板进行优化调整 */

:root {
  /* 颜色变量 - 调整为与系统主题一致 */
  --white: #ffffff;
  --gray: #7b7b7b;
  --primary-color: #53c157;
  --primary-light: #c6f3c7;
  --primary-dark: #388E3C;
  --accent-color: #fdad58;

  /* 圆角 */
  --button-radius: 0.7rem;

  /* 尺寸 */
  --max-width: 700px;
  --max-height: 450px;

  font-size: 15px;
  font-family: 'Helvetica Neue', Arial, sans-serif;
}

.login-page {
  align-items: center;
  background-color: var(--white);
  background: url("@/assets/images/login-bg.jpg");
  background-attachment: fixed;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
  display: grid;
  height: 100vh;
  place-items: center;
}

.form__title {
  font-weight: 600;
  margin: 0;
  margin-bottom: 1.2rem;
  color: var(--gray);
  font-size: 1.6rem;
}

.link {
  color: var(--primary-dark);
  font-size: 0.85rem;
  margin: 1.2rem 0;
  text-decoration: none;
  transition: color 0.3s ease;
}

.link:hover {
  color: var(--primary-color);
  text-decoration: underline;
}

.container {
  background: url("@/assets/images/login-bg.jpg");
  background-attachment: fixed;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
  border-radius: 12px;
  box-shadow: 0 1.5rem 3rem rgba(0, 0, 0, 0.3),
    0 1rem 1rem rgba(0, 0, 0, 0.2);
  height: var(--max-height);
  max-width: var(--max-width);
  overflow: hidden;
  position: relative;
  width: 100%;
}

.container__form {
  height: 100%;
  position: absolute;
  top: 0;
  transition: all 0.6s ease-in-out;
  background: url("@/assets/images/login-bg.jpg");
  background-attachment: fixed;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
}

.container--signin {
  left: 0;
  width: 50%;
  z-index: 2;
}

.container.right-panel-active .container--signin {
  transform: translateX(100%);
}

.container--signup {
  left: 0;
  opacity: 0;
  width: 50%;
  z-index: 1;
}

.container.right-panel-active .container--signup {
  animation: show 0.6s;
  opacity: 1;
  transform: translateX(100%);
  z-index: 5;
}

.container__overlay {
  height: 100%;
  left: 50%;
  overflow: hidden;
  position: absolute;
  top: 0;
  transition: transform 0.6s ease-in-out;
  width: 50%;
  z-index: 100;
}

.container.right-panel-active .container__overlay {
  transform: translateX(-100%);
}

.overlay {
  background-color: var(--primary-light);
  background: linear-gradient(135deg, #d0f0ce 0%, #338437 100%);
  height: 100%;
  left: -100%;
  position: relative;
  transform: translateX(0);
  transition: transform 0.6s ease-in-out;
  width: 200%;
}

.container.right-panel-active .overlay {
  transform: translateX(50%);
}

.overlay__panel {
  align-items: center;
  display: flex;
  flex-direction: column;
  height: 100%;
  justify-content: center;
  position: absolute;
  text-align: center;
  top: 0;
  transform: translateX(0);
  transition: transform 0.6s ease-in-out;
  width: 50%;
  padding: 0 40px;
}

.overlay__panel h1 {
  color: var(--white);
  font-size: 1.8rem;
  font-weight: 600;
  margin-bottom: 1.2rem;
}

.overlay__panel p {
  color: var(--white);
  font-size: 0.95rem;
  line-height: 1.4;
  margin-bottom: 1.8rem;
}

.overlay--left {
  transform: translateX(-20%);
}

.container.right-panel-active .overlay--left {
  transform: translateX(0);
}

.overlay--right {
  right: 0;
  transform: translateX(0);
}

.container.right-panel-active .overlay--right {
  transform: translateX(20%);
}

.btn {
  background-color: var(--primary-color);
  background-image: linear-gradient(90deg, var(--primary-dark) 0%, var(--primary-color) 74%);
  border-radius: 25px;
  border: 1px solid var(--primary-dark);
  color: var(--white);
  cursor: pointer;
  font-size: 0.85rem;
  font-weight: bold;
  letter-spacing: 0.1rem;
  padding: 0.8rem 3.5rem;
  text-transform: uppercase;
  transition: all 0.3s ease;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.form > .btn {
  margin-top: 1.2rem;
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 7px 10px rgba(0, 0, 0, 0.15);
}

.btn:active {
  transform: scale(0.95) translateY(0);
  box-shadow: 0 2px 3px rgba(0, 0, 0, 0.1);
}

.btn:focus {
  outline: none;
}

.btn.ghost {
  background: transparent;
  border: 2px solid var(--white);
}

.btn.ghost:hover {
  background: rgba(255, 255, 255, 0.1);
}

.form {
  background-color: rgba(255, 255, 255, 0.5);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  padding: 0 2.5rem;
  height: 100%;
  text-align: center;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.input {
  background-color: rgba(255, 255, 255, 0.8);
  border: none;
  border-radius: 8px;
  padding: 0.9rem 1.1rem;
  margin: 0.6rem 0;
  width: 100%;
  font-size: 0.95rem;
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
}

.input:focus {
  outline: none;
  background-color: rgba(255, 255, 255, 0.95);
  box-shadow: 0 0 0 2px var(--primary-light);
}

.input::placeholder {
  color: #aaaaaa;
}

.social-container {
  margin: 1rem 0;
}

.social-container a {
  border: 1px solid #dddddd;
  border-radius: 50%;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  margin: 0 5px;
  height: 40px;
  width: 40px;
  text-decoration: none;
  color: #666666;
  transition: all 0.3s ease;
}

.social-container a:hover {
  border-color: var(--primary-color);
  color: var(--primary-color);
  transform: translateY(-2px);
}

/* 动画效果 */
@keyframes show {
  0%, 49.99% {
    opacity: 0;
    z-index: 1;
  }
  50%, 100% {
    opacity: 1;
    z-index: 5;
  }
}

/* 响应式设计 */
@media (max-width: 768px) {
  .container {
    min-height: 480px;
    height: 80vh;
    width: 90%;
  }

  .form {
    padding: 0 1.5rem;
  }

  .overlay__panel {
    padding: 0 20px;
  }

  .overlay__panel h1 {
    font-size: 1.5rem;
  }

  .overlay__panel p {
    font-size: 0.9rem;
  }

  .btn {
    padding: 0.8rem 2.5rem;
  }
}

@media (max-width: 480px) {
  .container {
    height: 100vh;
    border-radius: 0;
    width: 100%;
  }

  .form__title {
    font-size: 1.5rem;
  }

  .btn {
    padding: 0.8rem 2rem;
    font-size: 0.8rem;
  }
}

.form-container input {
  background-color: #ffffff;
  border: 1px solid #e4e4e4;
  margin: 8px 0;
  padding: 10px 15px;
  font-size: 13px;
  border-radius: 8px;
  width: 100%;
  outline: none;
  transition: all 0.3s ease;
}

.form-container input:focus {
  background-color: rgba(83, 193, 87, 0.1);
  border-color: rgba(83, 193, 87, 0.3);
  box-shadow: 0 0 0 2px rgba(83, 193, 87, 0.1);
}

.form-container input:not(:placeholder-shown) {
  background-color: rgba(83, 193, 87, 0.05);
  border-color: rgba(83, 193, 87, 0.2);
}

.form-container input:not(:placeholder-shown):focus {
  background-color: rgba(83, 193, 87, 0.1);
  border-color: rgba(83, 193, 87, 0.3);
  box-shadow: 0 0 0 2px rgba(83, 193, 87, 0.1);
} 